package com.ldn.plugin.jc.bgx.dzs2501;

import com.ldn.common.basic.dispose.inter.PluginInterface;
import com.ldn.server.boot3.starter.feign.ServerMqtt;
import lombok.extern.slf4j.Slf4j;
import org.springframework.context.ApplicationContext;
import org.springframework.stereotype.Component;

import java.util.Map;

/**
 * TODO...
 *
 * @author 李大牛家的牛 (scafel@163.com)
 * @product serverless
 * @className Application
 * @createDate 2025/4/21 - 16:08
 * @description TODO...
 **/
@Slf4j
@Component
public class DZS2501 implements PluginInterface {


    private ServerMqtt serverMqtt;

    @Override
    public void setApplicationContext(Object applicationContext) {
        ApplicationContext app = (ApplicationContext) applicationContext;
        // 处理配置其他类或使用app.getBean 获取bean
        this.serverMqtt = app.getBean(ServerMqtt.class);
    }

    @Override
    public Object execute(String funName) {
        log.info("execute fun {}", funName);
        return null;
    }

    @Override
    public Object execute(String funName, Map<String, String> args) {
        log.info("execute fun {} args {}", funName, args);
        return null;
    }
}
